Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #237 +/- ##
==========================================
+ Coverage 90.18% 90.20% +0.01%
==========================================
Files 45 45
Lines 2273 2276 +3
==========================================
+ Hits 2050 2053 +3
Misses 223 223 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
a647981 to
aa69868
Compare
aa69868 to
1526ecd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
AttrR.updateandAttrR._on_update_callbacks->AttrR._update_callbackAttrR.set()->AttrR.update()AttrW.process()->AttrW.put(sync_setpoint: bool = False)sync_setpointAttrR._on_set_callbacks->AttrR._on_update_callbacksAttrRorAttrRWwithout an IO, this is left unset soupdatedoes nothing.AttrW._process_callbacks->AttrW._on_put_callback. This is called when a new value is put.AttrRWwithout an IO, the on_put_callback falls back toAttrRW.setso that internal driver parameters work as expected. This replaces the oldSimpleHandlerin a much simple way.AttrW._write_display_callbacks->AttrW._sync_setpoint_callbacksput(sync_setpoint=True)to update the setpoint of the attribute being put, e.g. when a driver is manually putting to attributes based on user input such as a fan outAttrRW.updatethe first time to initialise the setpoints so that they aren't blankOutstanding Questions
Should transports ever call put with sync_setpoint=True? This will update the setpoints of all transports. I think it is useful to not do this so that it is clear when looking at the UI for a transport that the put was from somewhere else.Should fan out attributes call put with sync_setpoint=True? I think yes because it is effectively a user input and the UI should reflect that.Do the callback names make sense? Shouldon_putjust beput, or something else?